<?php

namespace Rblog\Module\Admin\Controller;

class Index extends Common {

    private $_userData;
    protected $_working;
    protected $_screenName;
    protected $_currentUserid;


    public function __construct() {
        parent::__construct();
        //获取用户昵称
        $this->_userData = \Rexzy::model('User');
        $userid = $this->request->input( 'userid', 'c');
        $selectResult = $this->_userData->select( 'screenName', "where userid = $userid" );
        $this->_screenName = $selectResult['screenName'];
        $cookie = new \Rexzy\Tool\Cookie();
        $this->_currentUserid = $cookie->get( 'userid' );
        
        $this->view->assign( array(
            'work' => $this->_working, 
            'screenName' => $this->_screenName,
            'currentUserid' => $this->_currentUserid,
        ) );
        
    }
}
